package com.chixing.day_07_prototype.product;

public class Company implements Cloneable{
    private Integer companyId;
    private String companyName;
    private String companyType;
    private String companyAddress;
    private long companyTel;

    public Company(Integer companyId, String companyName, String companyType, String companyAddress, long companyTel) {
        this.companyId = companyId;
        this.companyName = companyName;
        this.companyType = companyType;
        this.companyAddress = companyAddress;
        this.companyTel = companyTel;
    }

    public Company() {
    }

    @Override
    protected Company clone() throws CloneNotSupportedException {
        Company cloneCompany = new Company();
        cloneCompany.companyId = this.companyId;
        cloneCompany.companyName = this.companyName;
        cloneCompany.companyType = this.companyType;
        cloneCompany.companyAddress = this.companyAddress;
        cloneCompany.companyTel = this.companyTel;
        return cloneCompany;
    }

    public Integer getCompanyId() {
        return companyId;
    }

    public void setCompanyId(Integer companyId) {
        this.companyId = companyId;
    }

    public String getCompanyName() {
        return companyName;
    }

    public void setCompanyName(String companyName) {
        this.companyName = companyName;
    }

    public String getCompanyType() {
        return companyType;
    }

    public void setCompanyType(String companyType) {
        this.companyType = companyType;
    }

    public String getCompanyAddress() {
        return companyAddress;
    }

    public void setCompanyAddress(String companyAddress) {
        this.companyAddress = companyAddress;
    }

    public long getCompanyTel() {
        return companyTel;
    }

    public void setCompanyTel(long companyTel) {
        this.companyTel = companyTel;
    }

    @Override
    public String toString() {
        return "Company{" +
                "companyId=" + companyId +
                ", companyName='" + companyName + '\'' +
                ", companyType='" + companyType + '\'' +
                ", companyAddress='" + companyAddress + '\'' +
                ", companyTel=" + companyTel +
                '}';
    }
}
